//
//  GQHContractModel.h
//  Xanthium
//
//  Created by GuanQinghao on 23/03/2018.
//  Copyright © 2018 GuanQinghao. All rights reserved.
//

#import "GQHBaseModel.h"
#import "GQHCommentModel.h"
#import "GQHContractExpenseModel.h"

@interface GQHContractModel : GQHBaseModel

/// 协议ID
@property (nonatomic, copy) NSString *qh_contractID;
/// 协议时间
@property (nonatomic, copy) NSString *qh_contractTime;
/// 协议状态
@property (nonatomic, copy) NSString *qh_contractState;
/// 协议补充内容
@property (nonatomic, copy) NSString *qh_contractAdditionalContent;
/// 协议郑重声明
@property (nonatomic, copy) NSString *qh_contractContent;
/// 协议价格详情
@property (nonatomic, strong) GQHContractExpenseModel *qh_contractExpenseModel;
/// 协议其他费用说明
@property (nonatomic, copy) NSString *qh_contractOtherExpenseNote;
/// 协议总金额
@property (nonatomic, assign) CGFloat qh_contractAmount;


/// 货源ID
@property (nonatomic, copy) NSString *qh_freightID;
/// 报价ID
@property (nonatomic, copy) NSString *qh_qutationID;
/// 货主头像
@property (nonatomic, copy) NSString *qh_ownerAvatar;
/// 货主姓名
@property (nonatomic, copy) NSString *qh_ownerName;
/// 货物重量
@property (nonatomic, assign) CGFloat qh_freightWeight;
/// 货物体积
@property (nonatomic, assign) CGFloat qh_freightVolume;
/// 货物数量
@property (nonatomic, assign) CGFloat qh_freightNumber;
/// 起始地行政编码
@property (nonatomic, copy) NSString *qh_departureID;
/// 起始地
@property (nonatomic, copy) NSString *qh_departure;
/// 目的地行政编码
@property (nonatomic, copy) NSString *qh_destinationID;
/// 目的地
@property (nonatomic, copy) NSString *qh_destination;
/// 公里数
@property (nonatomic, copy) NSString *qh_mileage;
/// 货物名称
@property (nonatomic, copy) NSString *qh_freightName;
/// 货物类型
@property (nonatomic, copy) NSString *qh_freightType;
/// 货物类型编码
@property (nonatomic, copy) NSString *qh_freightTypeCode;
/// 货源需求车型
@property (nonatomic, copy) NSString *qh_modelWanted;
/// 货源需求车长
@property (nonatomic, copy) NSString *qh_lengthWanted;
/// 货物单价
@property (nonatomic, assign) CGFloat qh_freightUnitPrice;
/// 业务类型
@property (nonatomic, copy) NSString *qh_businessTypeCode;
/// 运输方式
@property (nonatomic, copy) NSString *qh_transportTypeCode;
/// 装车时间
@property (nonatomic, copy) NSString *qh_loadingTime;
/// 收货人
@property (nonatomic, copy) NSString *qh_consignee;
/// 收货人电话
@property (nonatomic, copy) NSString *qh_consigneeMobile;
/// 收货时间
@property (nonatomic, copy) NSString *qh_consigningTime;


/// 司机ID
@property (nonatomic, copy) NSString *qh_driverID;
/// 司机头像
@property (nonatomic, copy) NSString *qh_driverAvatar;
/// 司机姓名
@property (nonatomic, copy) NSString *qh_driverName;
/// 司机手机号
@property (nonatomic, copy) NSString *qh_driverMobile;
/// 车牌号
@property (nonatomic, copy) NSString *qh_licensePlateNumber;
/// 车型编码
@property (nonatomic, copy) NSString *qh_modelCode;
/// 车型
@property (nonatomic, copy) NSString *qh_model;
/// 车辆标准车长
@property (nonatomic, copy) NSString *qh_normalLength;
/// 车辆标准载重
@property (nonatomic, copy) NSString *qh_normalLoading;
/**
 
 private String id;
 private String agreementTime;//协议时间
 private String agreementState;//协议状态
 private String addContent;//协议补充内容
 private String agreementText;//协议文本
 private AgreementJson aaAgreementJson;//协议价格详情
 private String otherExpensesNote;//其他费用说明
 private BigDecimal amount;//总金额
 
 private String sourcesInfoId;//货源信息ID 起始地、目的地、货物名称、货物类型、数量、重量、体积
 private String quotationId;//报价ID
 private String ownerPicture;//货主头像
 private String ownerName;//货主姓名
 private BigDecimal demandVehicle;//货物重量
 private BigDecimal goodsVolume;//货物体积
 private BigDecimal goodsNum;//货物数量
 private String origin;//起始地  行政区域表ID
 private String destination;//目的地  行政区域表ID
 private String commodityName;//货物名称
 private String demandModels;//需求车型
 private String demandVehicleLength;//需求车长
 private String freightUnitPrice;//运费单价
 private String businesstypecode;//业务类型  代码集查看内容
 private String transporttype;//运输方式   代码集查看内容
 private String loadingDate;//装车日期
 private String consignee;//收货人
 private String consigneePhone;//收货人电话
 private String goodsTime;//收货时间
 
 private String driverInfo;//司机信息 用户ID，司机认证信息  货车类型、车长
 private String driverPicture;//司机头像
 private String driverName;//司机名称
 private String licPlateNum;//车牌号
 private String vehicleclassificationcode;//车型     列表选择，参照代码集，表4 就是车辆分类代码
 private String carLength;//车长
 private String carLoad;//载重
 
 "id": "4028b881627b535d01627b89daed0023",
 "agreementTime": "2018-03-31 18:10:54",
 "agreementState": null,
 "addContent": null,
 "agreementText": "郑重声明：文本已丢失"
 +"aaAgreementJson": { … },
 "otherExpensesNote": null,
 "amount": null,
 
 "sourcesInfoId": "4028b881627b535d01627b6e93dc0014",
 "quotationId": "4028b881627b535d01627b76f353001b",
 "ownerName": "任旭庚",
 "ownerPicture": "4c36ad13-cea2-40cd-82fe-81a62d508318.jpg",
 "demandVehicle": 30,
 "goodsVolume": 1200,
 "goodsNum": 120,
 "origin": "石家庄市 高邑县",
 "destination": "邯郸市 鸡泽县",
 "commodityName": "玉米",
 "demandModels": "仓栅式货车",
 "demandVehicleLength": "17米",
 "freightUnitPrice": "1000.00",
 "businesstypecode": "1002998",
 "transporttype": "4",
 "loadingDate": "2018-03-31 12:38:22",
 "consignee": "收货人A",
 "consigneePhone": "12322221111",
 "goodsTime": "2018-11-12",
 
 "driverInfo": "4028b881627b535d01627b62b96b000a",
 "driverPicture": "4228c1a2692b4465899021eb76b161eb.jpg",
 "driverName": "司机11",
 "licPlateNum": "lic006",
 "vehicleclassificationcode": "普通货车",
 "carLength": "",
 "carLoad": "30",
 */

///  查看货源协议
+ (void)qh_fetchContractWithParameters:(NSDictionary *)parameters success:(void(^)(BOOL status, NSNumber *code, NSString *message, GQHContractModel *contract))success failure:(void(^)(NSError *error))failure;

@end
